Chart A
tmax_noaa = noaa_tidy |>
group_by(id, year, month) |>
summarize(mean_tmax = mean(tmax, na.rm = TRUE))
## `summarise()` has grouped output by 'id', 'year'. You can override using the
## `.groups` argument.
tmax_noaa |>
plot_ly(
x = ~year, y = ~mean_tmax, color = ~ month,
type = "scatter", mode = "markers", alpha = .5, text = "Data from the NOAA dataset"
)
## Warning: Ignoring 36342 observations
## Warning in RColorBrewer::brewer.pal(N, "Set2"): n too large, allowed maximum for palette Set2 is 8
## Returning the palette you asked for with that many colors
## Warning in RColorBrewer::brewer.pal(N, "Set2"): n too large, allowed maximum for palette Set2 is 8
## Returning the palette you asked for with that many colors